The classification theorem of compact surfaces states that every topological orientable compact surface is homeomorphic to a sphere or to a ‘torus’ of genus $g$, with $g\,=\,1,2,\dots$. It is proved in the paper that every hyperbolic Riemann surface except for $\bold D\setminus\{0\}$ can be decomposed into basic pieces of only a few different types: Y-pieces, funnels and half-disks. As a corollary of this result, the generalization of the classification theorem to non-compact surfaces is obtained.